package cn.wolfcode.business.mapper;

import cn.wolfcode.business.domain.BusAppointment;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

@Mapper
public interface BusAppointmentMapper {
    List<BusAppointment> selectBusAppointmentList(BusAppointment busAppointment);

    BusAppointment getInfo(Long id);

    Integer add(BusAppointment busAppointment);

    Integer update(BusAppointment newBusAppointment);

    Integer arrival(@Param("date") Date date, @Param("state") Integer state, @Param("id") Long id);

    Integer cancel(@Param("statusArrived") Integer statusArrived, @Param("id") Long id);

    Integer deleteById(Long id);

    int payUpdateStates(@Param("appointId") Long appointId, @Param("status") Integer status);
}
